]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
remoteSearch: Use GIcon instead of icon name
authorFlorian Müllner <fmuellner@gnome.org>
Fri, 22 Jun 2012 17:35:14 +0000 (19:35 +0200)
committerFlorian Müllner <fmuellner@gnome.org>
Mon, 25 Jun 2012 20:57:31 +0000 (22:57 +0200)
Currently we pass an icon name for the 'icon' parameter of the
RemoteSearchProvider constructor. In hindsight, using a GIcon
instead will give us a bit more flexibility, so change it.

https://bugzilla.gnome.org/show_bug.cgi?id=678816

js/ui/remoteSearch.js

index f0a40fe5a824bec2ca37dc0d5782a122be6347f8..6a03607ee43ae9f131e3afd32213b00ad5e5527d 100644 (file)
@@ -62,11 +62,12 @@ function loadRemoteSearchProvidersFromDir(dir, addProviderCallback) {
             let remoteProvider, title;
             try {
                 let group = KEY_FILE_GROUP;
-                let icon = keyfile.get_string(group, 'Icon');
+                let iconName = keyfile.get_string(group, 'Icon');
                 let busName = keyfile.get_string(group, 'BusName');
                 let objectPath = keyfile.get_string(group, 'ObjectPath');
                 title = keyfile.get_locale_string(group, 'Title', null);
 
+                let icon = new Gio.ThemedIcon({ name: iconName });
                 remoteProvider = new RemoteSearchProvider(title,
                                                           icon,
                                                           busName,